﻿using System.IO;

namespace Gmantis.Imaging
{
    internal enum FrameDisposal
    {
        None,
        Keep,
        RestoreBackground,
        RestorePrevious
    }

    internal class AnimationFrame
    {
        // Fields
        public Bitmap Bitmap;
        public int Delay;
        public FrameDisposal FrameDisposal;
        public Bitmap FrameImage;
        public Stream FrameStream;
        public int Height;
        public int Left;
        public int Top;
        public int Width;

        // Methods
        public AnimationFrame(GifInfo gif, Bitmap bmp)
        {
            this.Bitmap = bmp;
            this.Left = gif.Left;
            this.Top = gif.Top;
            this.Width = gif.ScreenWidth;
            this.Height = gif.ScreenHeight;
            this.Delay = gif.Delay;
            this.FrameDisposal = gif.FrameDisposal;
        }
    }
}
